Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pretty-hrtime

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pretty-hrtime

process.hrtime() to words

  • 0.2.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
3.4M
decreased by-43.38%
Maintainers
1
Weekly downloads
 
Created

What is pretty-hrtime?

The pretty-hrtime package is a small Node.js module that converts high-resolution time tuples (process.hrtime()) to a human-readable string. It is useful for logging and outputting performance timings in a format that is easier to comprehend than raw nanoseconds.

What are pretty-hrtime's main functionalities?

Convert high-resolution time to human-readable format

This feature allows you to take a high-resolution time tuple, such as the output from process.hrtime(), and convert it into a human-readable string that represents the elapsed time in words. This is useful for performance testing or timing operations in your applications.

const prettyHrtime = require('pretty-hrtime');
const start = process.hrtime();
// ... some time passes
const end = process.hrtime(start);
console.log(prettyHrtime(end));

Other packages similar to pretty-hrtime

Keywords

FAQs

Package last updated on 02 Oct 2014

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc